package com.zjs.vueRole.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.zjs.vueMenu.entity.VueMenu;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 * Created with IntelliJ IDEA.
 *
 * @author : zjs
 * @date : 2022/1/16 23:40
 * Description:
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(value="VueRole对象", description="角色")
public class VueRole implements Serializable {
    private static final long serialVersionUID = 6544507938632162628L;

    @ApiModelProperty(value = "菜单id")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;


    @ApiModelProperty(value = "橘色名称")
    private String roleName;

    @ApiModelProperty(value = "备注")
    private String remark;


    @ApiModelProperty(value = "创建时间")
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;

    @ApiModelProperty(value = "修改时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date updateTime;

    @ApiModelProperty(value = "二级菜单")
    @TableField(exist = false)
    private List<VueMenu> items = new ArrayList<>();
}
